//
// NeL - bindings
// Copyright (C) 2010 Naush
//
//This program is free software: you can redistribute it and/or modify
//it under the terms of the GNU Affero General Public License as
//published by the Free Software Foundation, either version 3 of the
//License, or (at your option) any later version.
//
//This program is distributed in the hope that it will be useful,
//but WITHOUT ANY WARRANTY; without even the implied warranty of
//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
//GNU Affero General Public License for more details.
//
//You should have received a copy of the GNU Affero General Public License
//along with this program.  If not, see <http://www.gnu.org/licenses/>.
package org.ryzom.nel.misc;

public final class TReportResult {
  public final static TReportResult ReportDebug = new TReportResult("ReportDebug");
  public final static TReportResult ReportIgnore = new TReportResult("ReportIgnore");
  public final static TReportResult ReportQuit = new TReportResult("ReportQuit");
  public final static TReportResult ReportError = new TReportResult("ReportError");

  public final int swigValue() {
    return swigValue;
  }

  public String toString() {
    return swigName;
  }

  public static TReportResult swigToEnum(int swigValue) {
    if (swigValue < swigValues.length && swigValue >= 0 && swigValues[swigValue].swigValue == swigValue)
      return swigValues[swigValue];
    for (int i = 0; i < swigValues.length; i++)
      if (swigValues[i].swigValue == swigValue)
        return swigValues[i];
    throw new IllegalArgumentException("No enum " + TReportResult.class + " with value " + swigValue);
  }

  private TReportResult(String swigName) {
    this.swigName = swigName;
    this.swigValue = swigNext++;
  }

  private TReportResult(String swigName, int swigValue) {
    this.swigName = swigName;
    this.swigValue = swigValue;
    swigNext = swigValue+1;
  }

  private TReportResult(String swigName, TReportResult swigEnum) {
    this.swigName = swigName;
    this.swigValue = swigEnum.swigValue;
    swigNext = this.swigValue+1;
  }

  private static TReportResult[] swigValues = { ReportDebug, ReportIgnore, ReportQuit, ReportError };
  private static int swigNext = 0;
  private final int swigValue;
  private final String swigName;
}

